<template>
  <div>
    <h2>{{ titleName }}</h2>
    <ul>
      <li v-for="(i, index) in dataList" :key="index">{{ i }}</li>
    </ul>
    <slot name="aaa">默认占位符a</slot>
    <slot name="bbb">默认占位符b</slot>
  </div>
</template>

<script>
export default {
  props: ["dataList", "titleName"],
};
</script>

<style scoped>
div {
  background-color: orange;
  width: 200px;
  text-align: center;
}
</style>